<?php
/**
 * Hello Model for Hello World Component
 * 
 * @package    Joomla.Tutorials
 * @subpackage Components
 * @link http://dev.joomla.org/component/option,com_jd-wiki/Itemid,31/id,tutorials:components/
 * @license		GNU/GPL
 */

// Check to ensure this file is included in Joomla!
defined('_JEXEC') or die();

jimport( 'joomla.application.component.model' );

/**
 * Hello Model
 *
 * @package    Joomla.Tutorials
 * @subpackage Components
 */
class VinachartModelListarticle extends JModel
{
	/**
	 * Gets the greeting
	 * @return string The greeting to be displayed to the user
	 */
	function getListArticle()
	{
                //default article get
                $catid = '14';
                
		$db = &JFactory::getDBO();
                $query = 'SELECT * FROM #__content as c WHERE c.catid = "'.$catid.'"';
                $db->setQuery($query);
                return $db->loadObjectList();
	}
}
